package cn.service.Impl;

import cn.mapper.CustomerMapper;
import cn.pojo.Customer;
import cn.pojo.CustomerExample;
import cn.service.CustomerService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author jia
 * @Description
 * @date 2019-03-21-1:17
 */
@Service
public class CustomerServiceImpl implements CustomerService {
    @Autowired
    CustomerMapper customerMapper;

    @Override
    public List<Customer> list() {
        CustomerExample example = new CustomerExample();
        example.setOrderByClause("id desc");
        return customerMapper.selectByExample(example);
    }
}
